package com.example.kehoobackend.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

@Data
@TableName(value = "collection",autoResultMap = true)
public class Collection {

    //收藏ID
    @TableId(value = "collection_id",type = IdType.AUTO)
    private Integer collection_id;

    //回答ID
    private Integer answer_id;

    //收藏时间
    private String create_time;

    //用户ID
    private Integer user_id;

    // 对应的问题ID
    @TableField(exist = false)
    private Integer question_id;

    //问题标题
    @TableField(exist = false)
    private String question_title;

    // 回答内容
    @TableField(exist = false)
    private String answer_content;
}
